.TH E1432_SET_ANALOG_INPUT 3 E1432
.SH NAME
e1432_set_analog_input \- Set all analog input parameters
.IX e1432_set_analog_input(3) 3
.SH SYNOPSIS
.cS
SHORTSIZ16 e1432_set_analog_input(E1432ID hw, SHORTSIZ16 ID,
                                  SHORTSIZ16 mode, SHORTSIZ16 source,
                                  SHORTSIZ16 state, SHORTSIZ16 coupling,
                                  FLOATSIZ32 range)
.cE
.SH DESCRIPTION
\fIe1432_set_analog_input\fR sets many of the parameters associated
with the analog input section of an E1432 or group of E1432s,
effectively combining a number of individual parameter function calls.
Please refer to the documentation for the individual parameter
functions for more specific information.

\fIhw\fR must be the result of a successful call to
\fIe1432_assign_channel_numbers\fR, and specifies the group of
hardware to talk to.

\fIID\fR is either the ID of a group of channels that was obtained with a
call to \fIe1432_create_channel_group\fR, or the ID of a single channel.

\fImode\fR determines the input mode in the front end.  This parameter
may also be set with \fIe1432_set_input_mode\fR.  Changing the input
mode for one channel causes the input mode for all channels within
that SCA to change.  See \fIe1432_set_input_mode\fR for more details.

\fIsource\fR selects the input to the ADC.
\fBE1432_INPUT_HIGH_NORMAL\fR selects the front panel connector.
\fBE1432_INPUT_HIGH_GROUNDED\fR grounds the ADC input.
\fBE1432_INPUT_HIGH_CALIN\fR selects the module's CALIN line.
\fBE1432_INPUT_HIGH_BOB_CALIN\fR selects the module's CALIN line via
the cal connection in a break-out box.

This parameter may also be set with \fIe1432_set_input_high\fR.

\fIstate\fR determines the state of the analog anti-alias filter in
the front end.  The analog anti-alias filters of the E143x modules
can't be disabled, so this value must be set to
\fBE1432_ANTI_ALIAS_ANALOG_ON\fR.  This parameter may also be set with
\fIe1432_set_anti_alias_analog\fR.

\fIcoupling\fR determines the AC or DC coupling mode of the input.
Using \fBE1432_COUPLING_DC\fR will connect the input directly to the amplifier.
\fBE1432_COUPLING_AC\fR inserts a series capacitor between the input
and the amplifier.  
This parameter may also be set with \fIe1432_set_coupling\fR.

\fIrange\fR is the full scale range in volts (or in picoCoulombs if
the input mode is set to charge mode).  Signal inputs whose absolute
value is larger than full scale will generate an ADC overflow error.
The possible values for \fIrange\fR depend on the type of channel
being programmed.  The actual range that is set will be the nearest
legal range value that is greater than or equal to the value specified
by the \fIrange\fR parameter.

If the mode is set to voltage or ICP, this function uses
\fIe1432_set_range\fR to set the range.  If the mode is set to charge
mode, this function uses \fIe1432_set_range_charge\fR to set the
charge-amp range.  If the mode is set to microphone mode, this
function uses \fIe1432_set_range_mike\fR to set the microphone range.

The corresponding E1431 function takes an extra parameter to specify
whether the ground path is floating or grounded.  This function does
not take this parameter, since the E1432 hardware can't set this
programmatically.  Instead, there is a switch which controls the
grounding, on the break-out box that connects to the inputs.
.ne 6
.SH "RESET VALUE"
After a reset, \fImode\fR is set to \fBE1432_INPUT_MODE_VOLT\fR.
The \fIsource\fR is set to \fBE1432_INPUT_SOURCE_BNC\fR, \fIstate\fR
is set to \fBE1432_ANTI_ALIAS_ANALOG_ON\fR, \fIcoupling\fR is set to
\fBE1432_COUPLING_DC\fR, and \fIrange\fR is set to the maximum legal
value for each channel.
.ne 8
.SH "RETURN VALUE"
Return 0 if successful, a (negative) error number otherwise.
.ne 4
.SH "SEE ALSO"
.na
e1432_set_anti_alias_analog, e1432_set_coupling,
e1432_set_input_mode, e1432_set_input_high, e1432_set_range,
e1432_set_range_charge, e1432_set_range_mike.
.ad
